/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

/*
 * JFlavourItemEditorTopComponent.java
 *
 * Created on 9 Aug, 2014, 10:10:22 AM
 */

package org.sil.JFLavourItemEditor;

import org.openide.windows.TopComponent;

/**
 *
 * @author toby
 */
public class JFlavourItemEditorTopComponent extends TopComponent {

    /** Creates new form JFlavourItemEditorTopComponent */
    public JFlavourItemEditorTopComponent() {
        initComponents();
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        txtItemLabel = new javax.swing.JTextField();
        btnCancel = new javax.swing.JButton();
        btnApply = new javax.swing.JButton();
        btnClose = new javax.swing.JButton();
        panelCategories = new javax.swing.JPanel();
        labelCategories = new javax.swing.JLabel();
        txtCategories = new javax.swing.JTextField();
        jScrollPane4 = new javax.swing.JScrollPane();
        panelCategoriesList = new javax.swing.JPanel();
        jLabel1 = new javax.swing.JLabel();
        panelImages = new javax.swing.JPanel();
        labelImages = new javax.swing.JLabel();
        btnBrowseImages = new javax.swing.JButton();
        jScrollPane5 = new javax.swing.JScrollPane();
        panelImagesList = new javax.swing.JPanel();
        panelAudio = new javax.swing.JPanel();
        labelAudio = new javax.swing.JLabel();
        btnBrowseAudio = new javax.swing.JButton();
        jScrollPane6 = new javax.swing.JScrollPane();
        panelAudioList = new javax.swing.JPanel();
        panelImagePreview = new javax.swing.JPanel();

        txtItemLabel.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                txtItemLabelActionPerformed(evt);
            }
        });

        btnCancel.setText("Cancel");
        btnCancel.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnCancelActionPerformed(evt);
            }
        });

        btnApply.setText("Apply");

        btnClose.setText("Close");

        labelCategories.setText("Categories");

        org.jdesktop.layout.GroupLayout panelCategoriesListLayout = new org.jdesktop.layout.GroupLayout(panelCategoriesList);
        panelCategoriesList.setLayout(panelCategoriesListLayout);
        panelCategoriesListLayout.setHorizontalGroup(
            panelCategoriesListLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 155, Short.MAX_VALUE)
        );
        panelCategoriesListLayout.setVerticalGroup(
            panelCategoriesListLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 307, Short.MAX_VALUE)
        );

        jScrollPane4.setViewportView(panelCategoriesList);

        jLabel1.setText("use comma between");

        org.jdesktop.layout.GroupLayout panelCategoriesLayout = new org.jdesktop.layout.GroupLayout(panelCategories);
        panelCategories.setLayout(panelCategoriesLayout);
        panelCategoriesLayout.setHorizontalGroup(
            panelCategoriesLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(panelCategoriesLayout.createSequentialGroup()
                .addContainerGap()
                .add(panelCategoriesLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, jScrollPane4)
                    .add(labelCategories, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(txtCategories)
                    .add(jLabel1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );
        panelCategoriesLayout.setVerticalGroup(
            panelCategoriesLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(panelCategoriesLayout.createSequentialGroup()
                .addContainerGap()
                .add(labelCategories)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jScrollPane4, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 263, Short.MAX_VALUE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(txtCategories, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jLabel1)
                .addContainerGap())
        );

        labelImages.setText("Images");

        btnBrowseImages.setText("Browse...");
        btnBrowseImages.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                btnBrowseImagesActionPerformed(evt);
            }
        });

        org.jdesktop.layout.GroupLayout panelImagesListLayout = new org.jdesktop.layout.GroupLayout(panelImagesList);
        panelImagesList.setLayout(panelImagesListLayout);
        panelImagesListLayout.setHorizontalGroup(
            panelImagesListLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 148, Short.MAX_VALUE)
        );
        panelImagesListLayout.setVerticalGroup(
            panelImagesListLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 305, Short.MAX_VALUE)
        );

        jScrollPane5.setViewportView(panelImagesList);

        org.jdesktop.layout.GroupLayout panelImagesLayout = new org.jdesktop.layout.GroupLayout(panelImages);
        panelImages.setLayout(panelImagesLayout);
        panelImagesLayout.setHorizontalGroup(
            panelImagesLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, panelImagesLayout.createSequentialGroup()
                .addContainerGap()
                .add(panelImagesLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(jScrollPane5)
                    .add(org.jdesktop.layout.GroupLayout.LEADING, labelImages, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(org.jdesktop.layout.GroupLayout.LEADING, btnBrowseImages, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );
        panelImagesLayout.setVerticalGroup(
            panelImagesLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(panelImagesLayout.createSequentialGroup()
                .addContainerGap()
                .add(labelImages)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jScrollPane5, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(btnBrowseImages)
                .addContainerGap())
        );

        labelAudio.setText("Audio");

        btnBrowseAudio.setText("Browse...");

        org.jdesktop.layout.GroupLayout panelAudioListLayout = new org.jdesktop.layout.GroupLayout(panelAudioList);
        panelAudioList.setLayout(panelAudioListLayout);
        panelAudioListLayout.setHorizontalGroup(
            panelAudioListLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 148, Short.MAX_VALUE)
        );
        panelAudioListLayout.setVerticalGroup(
            panelAudioListLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 305, Short.MAX_VALUE)
        );

        jScrollPane6.setViewportView(panelAudioList);

        org.jdesktop.layout.GroupLayout panelAudioLayout = new org.jdesktop.layout.GroupLayout(panelAudio);
        panelAudio.setLayout(panelAudioLayout);
        panelAudioLayout.setHorizontalGroup(
            panelAudioLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(org.jdesktop.layout.GroupLayout.TRAILING, panelAudioLayout.createSequentialGroup()
                .addContainerGap()
                .add(panelAudioLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(jScrollPane6)
                    .add(org.jdesktop.layout.GroupLayout.LEADING, labelAudio, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(org.jdesktop.layout.GroupLayout.LEADING, btnBrowseAudio, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addContainerGap())
        );
        panelAudioLayout.setVerticalGroup(
            panelAudioLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(panelAudioLayout.createSequentialGroup()
                .addContainerGap()
                .add(labelAudio)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(jScrollPane6, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(btnBrowseAudio)
                .addContainerGap())
        );

        org.jdesktop.layout.GroupLayout panelImagePreviewLayout = new org.jdesktop.layout.GroupLayout(panelImagePreview);
        panelImagePreview.setLayout(panelImagePreviewLayout);
        panelImagePreviewLayout.setHorizontalGroup(
            panelImagePreviewLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 149, Short.MAX_VALUE)
        );
        panelImagePreviewLayout.setVerticalGroup(
            panelImagePreviewLayout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(0, 100, Short.MAX_VALUE)
        );

        org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(layout.createSequentialGroup()
                .addContainerGap()
                .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING)
                    .add(layout.createSequentialGroup()
                        .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                            .add(layout.createSequentialGroup()
                                .add(txtItemLabel, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 181, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .add(18, 18, 18)
                                .add(panelImagePreview, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                            .add(layout.createSequentialGroup()
                                .add(panelCategories, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                                .add(panelImages, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                                .add(0, 6, Short.MAX_VALUE)))
                        .add(panelAudio, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                    .add(layout.createSequentialGroup()
                        .add(0, 0, Short.MAX_VALUE)
                        .add(btnCancel)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(btnApply, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 62, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                        .add(btnClose, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 64, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)))
                .addContainerGap())
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
            .add(layout.createSequentialGroup()
                .addContainerGap()
                .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(txtItemLabel, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)
                    .add(panelImagePreview, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)
                .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
                    .add(panelAudio, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(panelImages, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .add(org.jdesktop.layout.GroupLayout.TRAILING, panelCategories, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED)
                .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE)
                    .add(btnCancel)
                    .add(btnApply)
                    .add(btnClose))
                .addContainerGap())
        );
    }// </editor-fold>//GEN-END:initComponents

    private void btnBrowseImagesActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnBrowseImagesActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_btnBrowseImagesActionPerformed

    private void btnCancelActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnCancelActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_btnCancelActionPerformed

    private void txtItemLabelActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_txtItemLabelActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_txtItemLabelActionPerformed


    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton btnApply;
    private javax.swing.JButton btnBrowseAudio;
    private javax.swing.JButton btnBrowseImages;
    private javax.swing.JButton btnCancel;
    private javax.swing.JButton btnClose;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JScrollPane jScrollPane5;
    private javax.swing.JScrollPane jScrollPane6;
    private javax.swing.JLabel labelAudio;
    private javax.swing.JLabel labelCategories;
    private javax.swing.JLabel labelImages;
    private javax.swing.JPanel panelAudio;
    private javax.swing.JPanel panelAudioList;
    private javax.swing.JPanel panelCategories;
    private javax.swing.JPanel panelCategoriesList;
    private javax.swing.JPanel panelImagePreview;
    private javax.swing.JPanel panelImages;
    private javax.swing.JPanel panelImagesList;
    private javax.swing.JTextField txtCategories;
    private javax.swing.JTextField txtItemLabel;
    // End of variables declaration//GEN-END:variables

    @Override
    public int getPersistenceType() {
        return PERSISTENCE_NEVER;
    }
}
